<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
  <meta name="renderer" content="webkit" />
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
  <title>千锋教育大前端Vue教学</title>
  <!-- 引入vue -->
  <script src="https://cdn.staticfile.org/vue/3.0.5/vue.global.js"></script>
  <style>
    .container { margin: 40px; }
    .row { display: flex; flex-direction: row; margin: 6px 0px; }
    .name { font-weight: 900; width: 80px; }
    .score { width: 80px; color: gray; }
  </style>
</head>
<body style="margin:100px;font-size:22px;">
  <script>
    const list = [
      { name: '张三', chinese: 96, math: 99, english: 89 },
      { name: '李四', chinese: 92, math: 96, english: 98 },
      { name: '王五', chinese: 87, math: 89, english: 92 },
    ];
  </script>
  <div id="app">
    <div class="container">
      <div class="row" v-for="o in list" :key="o.name">
        <div class="name">{{o.name}}：</div>
        <div class="score">{{o.chinese}}</div>
        <div class="score">{{o.math}}</div>
        <div class="score">{{o.english}}</div>
      </div>
    </div>
  </div>
  <script>
    // 创建应用
    const app = Vue.createApp({
      // 初始化数据
      data() { return { list } }
    });
    // 挂载应用
    app.mount('#app'); // 类似：el.innerHTML = html; // 设置html
  </script>
</body>
</html>